Strictness Types: An Inference Algorithm and an Application
نویسنده
چکیده
This report deals with strictness types, a way of recording whether a function needs its argument(s) or not. We shall present an inference system for assigning strictness types to expressions and subsequently we transform this system into an algorithm capable of annotating expressions with strictness types. We give an example of a transformation which can be optimized by means of these annotations, and finally we prove the correctness of the optimized transformation — at the same time proving the correctness of the annotation. Everything has been implemented; documentation can be found in appendix.
منابع مشابه
Inference of polymorphic and conditional strictness propertiesThomas
We deene an inference system for modular strictness analysis of functional programs by extending a conjunctive strictness logic with polymorphic and conditional properties. This extended set of properties is used to deene a syntax-directed, polymorphic strictness analysis based on polymorphic recur-sion whose soundness is established via a translation from the polymorphic system into the conjun...
متن کاملEfficient computation of strictness types∗
Amtoft has formulated an “on-line” constraint normalization method for solving a strictness inference problem inspired by Wright. From the syntactic form of the normalized constraints he establishes that every program expression has a unique, most precise (“minimal”) strictness judgement, given fixed values for the strictness annotation in negative position. We show that his on-line normalizati...
متن کاملDerivation and inference of higher-order strictness types
We extend an existing first-order typing system for strictness analysis to the fully higher-order case, covering both the derivation system and the inference algorithm. The resulting strictness typing system has expressive capabilities far beyond that of traditional strictness analysis systems. This extension is developed with the explicit aim of formally proving soundness of higher-order stric...
متن کاملType Inference, Abstract Interpretation and Strictness Analysis
Coppo, M. and A. Ferrari, Type inference, abstract interpretation and strictness analysis, Theoretical Computer Science 121 (1993) 113-143. Filter domains (Coppo et al., 1984) can be seen as abstract domains for the interpretation of (functional) type-free programming languages. What is remarkable is the fact that in filter domains the interpretation of a term is given by the set of its types i...
متن کاملOn Strictness and Totality
Abs t rac t . In this paper we present a revised and extended version of the strictness and totality type assignment system introduced by Solberg, Nielson and Nielson in the Static Analysis Symposium '9~. Our main result is that (w.r.t. the possibility of replacing safely a lazy application by a strict one) the strictness and totality information given by this system is equivalent to the inform...
متن کامل